package com.eurasia.assignment.controller.dto;

import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Pattern;
import lombok.Data;

/**
 * 更新班级请求对象
 */
@Data
public class UpdateClassRequest {
    @NotBlank(message = "班级名称不能为空")
    private String className;
    
    @NotBlank(message = "年级不能为空")
    @Pattern(regexp = "\\d{4}", message = "年级格式不正确，应为四位数字（如：2024）")
    private String grade;
    
    @NotBlank(message = "专业不能为空")
    private String major;
    
    @NotBlank(message = "班主任不能为空")
    private String tutor;
    
    @Min(value = 0, message = "学生数量不能为负数")
    private Integer studentCount;
    
    private String remark;
}
